home *** CD-ROM | disk | FTP | other *** search
/ Tech Arsenal 1 / Tech Arsenal (Arsenal Computer).ISO / tek-19 / 3dgraph.zip / 3DGRAPH.DOC next >
Text File  |  1991-05-03  |  14KB  |  356 lines

  1.  
  2.  
  3.  
  4.  
  5.  
  6.  
  7.  
  8.  
  9.  
  10.  
  11.  
  12.  
  13.  
  14.  
  15.  
  16.  
  17.  
  18.                                 3d Surface Grapher
  19.  
  20.                                    3dGraph v1.0
  21.  
  22.                                   by Dan Schikore
  23.  
  24.                                      05/03/91
  25.  
  26.  
  27.  
  28.                                        INDEX
  29.  
  30. 1. Disclaimer                 - page 1
  31.  
  32. 2. Shareware Notice           - page 1
  33.  
  34. 3. System Requirements        - page 2
  35.  
  36. 4. Definitions                - page 2
  37.  
  38. 5. The equation types         - page 3
  39.  
  40. 6. The Menu System            - page 4
  41.     a) How to use it
  42.     b) The Surface Menu
  43.     c) The Graph Menu
  44.     d) The Options Menu
  45.  
  46. 7. The Surface Menu Commands  - page 5
  47.  
  48. 8. The Graph Menu Commands    - page 6
  49.  
  50. 9. The Options                - page 7
  51.  
  52. 10. Graph Mode Commands       - page 8
  53.  
  54.  
  55.                               - page 1 -
  56.  
  57.  
  58. 1. Disclaimer
  59.  
  60.     This program is provided without any warranty of any kind.  The
  61. author will not be responsible for any damage of any kind due to the use
  62. of this program.
  63.  
  64.  
  65.  
  66. 2. Shareware Notice
  67.  
  68.         This program is Shareware.  It is provided with full feature
  69. capability for you to examine and determine if it is of any use to you.
  70. You are encouraged to distribute it as long as all original files are
  71. included unmodified (except the data file), and no charges other than
  72. disk copying fees are charged.  You are free to use the program for your
  73. personal use for two weeks.  If you would like to continue using it,
  74. please register to encourage development of this and other shareware
  75. programs.  Registered users will be notified of update opportunities by
  76. mail.  To register a personal version, print or copy the file register.doc,
  77. fill it out, and send it along with $10 check or money order to:
  78.  
  79.    Dan Schikore
  80.    1983 Greenheath
  81.    Florissant, MO 63033
  82.  
  83. If 3dGraph is being registered for a network or use on other groups of
  84. computers by different users, the registration is:
  85.  
  86.    2- 5 computers - $15
  87.    6-10 computers - $25
  88.   11-19 computers - $35
  89.   20+   computers - $50
  90.  
  91. Comments and suggestions are welcome.
  92.  
  93.  
  94.                               - page 2 -
  95.  
  96. 3. System Requirements
  97.  
  98.     This program will operate on any PC-compatible computer with a
  99. minimum of 640K of memory.  All major video modes are supported.  The
  100. printer functions were developed for use with 9 and 24 pin Star printers
  101. and are compatible with most dot matrix printers.  A coprocessor is
  102. helpful but not necessary.
  103.  
  104.  
  105.  
  106. 4. Definitions
  107.  
  108.         Surface - A surface consists of a function of one or two variables,
  109. from any of six types of equations, along with parameters which specify
  110. the limits of the variables x and y, the skip values for x and y (Skip
  111. values define how many lines of the grid surface will be graphed when in
  112. Graph Mode, a skip of 2 means every second line will be graphed), the
  113. number of data points to be used in the surface (increasing the number of
  114. data points increases the accuracy of the representation of the graph, and
  115. decreases the speed of calculations and drawing), and the center of the
  116. surface (Specifies a translation of the surface so a sphere can be centered
  117. at (1,0,0) by defining a sphere at the origin and setting the center of
  118. the surface to (1,0,0) ).
  119.  
  120.     Graph - a graph can contain up to six surfaces.  All graphs must
  121. contain at least one surface.  2d and 3d functions can be mixed in the
  122. same graph.
  123.  
  124.                               - page 3 -
  125.  
  126. 5. The equation types
  127.  
  128.         There are six basic types of equations available:
  129.  
  130.                 i) y=f(x)
  131.                ii) z=f(x,y)
  132.               iii) T[x]=( f(x), g(x) )
  133.                iv) T[x,y]= ( f(x,y), g(x,y) )
  134.                 v) T[x]=( f(x), g(x), h(x) )
  135.                vi) T[x,y]=( f(x,y), g(x,y), h(x,y) )
  136.  
  137.         When specifying a domain for x and y, the limits must be constant
  138. expressions.  All operators and functions available in functions are
  139. allowed but x and y are not.  Constants e and pi are defined.  Equation
  140. types i) and ii) can be used for most functions, such as a paraboloid
  141. ( z=x^2 + y^2 ), however for graphs which appear circular, you may not get
  142. the desired effect, and it would be better to use a parametric
  143. representation of the surface.  For a paraboloid, this would be
  144. T[x,y] = ( ysin(x), ycos(x), y^2 ).  For other surfaces, like a sphere,
  145. there is really no choice.  To graph the upper half of a sphere of radius 1,
  146. we would have z=sqrt(1 - x^2 - y^2),
  147.               -1 <= x <= 1
  148.               -1 <= y <= 1
  149. but at some places on this domain, such as (-1, 1), z would be undefined.
  150.  
  151. For some of the more popular equations, there are predefined equations that
  152. can be used to create paraboloids, ellipses, tori, and others.
  153.  
  154. The equations for f, g, and h can contain the following operators:
  155.  
  156.      +, - , *, /, ^
  157.  
  158. The functions recognized are:
  159.  
  160.      abs, cos, cosh, sin, sinh, tan, tanh, sqrt, exp, ln, log
  161.  
  162. And the constants PI and E are defined.
  163.  
  164. The usual rules for precedence are observed.
  165.  
  166. In many cases, the * operator can be omitted, for equations like f(x)=5x.
  167.  
  168. Unless parentheses are used, the unary operators and functions
  169. ( -, cos, sin, tan ...) operate on only the next operator in the
  170. equation.  For example:
  171.  
  172.       sin5x = (sin(5))*x, while
  173.       sin(5x) = sin(5*x)
  174.  
  175.                               - page 4 -
  176.  
  177. 6. The menu system
  178.  
  179.         a) How to use it - The menus can be controlled several ways.
  180. The menu which is highlighted is the current menu.  To pull down the
  181. options for a menu, press <ENTER> or <DOWN>.  <ESC> will remove the menu
  182. and return to the top level.  When a menu is pulled down, <UP> and <DOWN>
  183. move the highlight bar within the menu.  To make a selection, press <ENTER>.
  184. <LEFT> and <RIGHT> will change the current menu.
  185.  
  186.         b) The Surface menu - The surface menu contains all of the options
  187. necessary to Create and Edit Surfaces in the current Graph.  None of the
  188. options in this menu can be used until a graph has been loaded or created
  189. using either the Load or New options from the Graph Menu.  The options
  190. available are:
  191.  
  192.                  i) Add - Add a Surface to the current Graph
  193.                 ii) Change - Change the current surface
  194.                iii) Delete - Delete a Surface from the current Graph
  195.                 iv) Edit - Edit the current surface
  196.                  v) Graph - Graph all surfaces in the current Graph
  197.  
  198. For more details on the Surface Menu commands see page 5
  199.  
  200.         b) The Graph menu - The Graph menu will allow the user to create
  201. new graphs, load a graph, or save the current graphs to the data file.  All
  202. the graphs actually remain in memory the entire time, so loading a graph
  203. actually only selects the current graph.  Available options:
  204.  
  205.                  i) Add - Add a new Graph
  206.                 ii) Delete - Delete a Graph
  207.                iii) Load - Load a Graph
  208.                 iv) Save - Save the graphs to the graph datafile
  209.  
  210. For more details on the Graph Menu commands see page 6
  211.  
  212.         b) The Options menu - The Options menu can be used to configure
  213. the program for your specific needs.  Use this menu to set the printer
  214. type, printer port, specify whether colors should be used, whether double
  215. buffering should be used, and the increment of angles to be used when
  216. rotating the graph in Graph Mode.  Available options are:
  217.  
  218.                  i) Edit - Edit the current setup
  219.                 ii) Display - Show the current setup
  220.                iii) Save Setup - Save the current setup
  221.  
  222. For more details on the options see page 7
  223.  
  224.                               - page 5 -
  225.  
  226. 7. The Surface Menu Commands
  227.  
  228.        i) Add - To add a surface to the current graph, select Add from
  229. the Surface menu.  A menu with the different equation types will appear.
  230. Highlight the desired type of equation and press <ENTER>.  If you choose
  231. a predefined equation, you will be asked to supply various parameters
  232. depending on what surface you choose.  You will then be placed in the
  233. Edit mode for the Surface which allows you to specify the other Surface
  234. parameters.
  235.  
  236.       ii) Change - Change allows you to change the current surface within
  237. the current graph.  A menu will pop up with the names of the surfaces in
  238. the current graph, allowing you to select the new current surface.
  239.  
  240.      iii) Delete - Choosing delete from the Surface menu will bring up
  241. a menu with the names of all surfaces which are part of the current
  242. graph, allowing you to choose a surface to delete.  All graphs must
  243. contain at least one surface, so if you try to delete a surface from
  244. a graph which only has one surface, you will get an error.
  245.  
  246.       iv) Edit - Edit places you into Edit mode on the current surface.
  247. You can change the name of the current graph or the current surface,
  248. change any of the equations, the limits of x and y, the step values for
  249. x and y, the number of data points, and the center of the surface.  When
  250. editing an equation or a graph or surface name, you are essentially in
  251. insert mode, where any character you type is inserted at the position of
  252. the cursor.  The backspace deletes the character before the cursor, and
  253. the delete key deletes the character under the cursor.  Using the <LEFT>
  254. and <RIGHT> keys allow you to move back and forth in the string.  The
  255. <UP> and <DOWN> keys allow you to move from field to field in the
  256. surface specification, cancelling any changes that have been made in
  257. the current field.  <ENTER> accepts the current changes and advances
  258. to the next field.  To quit edit mode, press <ESC>.  When editing
  259. equations, you will not be allowed to move or quit until a "legal"
  260. expression has been entered.
  261.  
  262.        v) Graph - Graph will enter graph mode and Graph all of the
  263. surfaces contained in the current graph.  See Graph Mode Commands on
  264. page 8 for more details.
  265.  
  266.  
  267.                               - page 6 -
  268.  
  269. 8. Graph Menu commands
  270.  
  271.        i) Add - Selecting new allows the user to create a new graph,
  272. and immediately prompts the user for an equation type for the first
  273. surface to add the the graph, since all graphs must contain at least
  274. one surface.
  275.  
  276.       ii) Delete - Delete a graph from the list of graphs.  Choosing
  277. this option will bring up a menu with the names of all of the graphs,
  278. allowing the user to choose a graph to delete.  This will NOT update
  279. the data file in any way.  If this change is supposed to be permanent,
  280. follow the Delete command with a Save command.
  281.  
  282.      iii) Load - Choosing Load allows the user to choose a current
  283. graph from the list of graphs.  The current surface becomes the first
  284. surface in the list of surfaces for this graph.
  285.  
  286.       iv) Save - Save rewrites the datafile of graphs, updating any
  287. changes you have made in the current session.
  288.  
  289.                               - page 7 -
  290. 9. The Options
  291.  
  292.        i) Printer Type - 3dGraph supports 9 and 24-pin dot matrix
  293. printing.  It was developed for use with a Star printer, but has been
  294. used on a variety of different printers and found to be compatible.
  295.  
  296.       ii) Printer Port - There are 6 options for the printer port,
  297. LPT1-2, and COM1-4.  The program has NOT been tested using the COM
  298. port configurations, but I would be interested in hearing how it works.
  299.  
  300.      iii) Graphing Colors - If the program is configured to use colors,
  301. and the monitor being used supports 16 colors or more, the graph will
  302. be displayed in a spectrum of colors showing the contours.  If the
  303. monitor does not support 16 colors, this option will be ignored.
  304.  
  305.       iv) Double Buffering - Double buffering can be used on some
  306. monitors, allowing the drawing to be done on a separate graphics screen,
  307. and then displayed quickly so the redrawing is not noticeable.  The
  308. problem with this is that while it is drawing the delay may cause the
  309. user to think the key was not detected.  Turning this option off will
  310. draw on the currently displayed screen all of the time, so you can see
  311. when the computer is working.  This is the default on monitors which do
  312. not support double buffering.
  313.  
  314.        v) Angle step - When rotating the graph in Graph Mode, this
  315. option specifies how many degrees to rotate the graph with each keypress.
  316. Allowable values are 1-15.
  317.  
  318.                               - page 8 -
  319.  
  320. 10. Graph Mode commands
  321.  
  322.         While in graph mode, there are many commands to modify the display.
  323. The viewpoint is specified by two angles, phi and theta, similar to the
  324. angles used in a spherical coordinate system.  Using the arrow keys modify
  325. the angles as follows:
  326.  
  327.                  i) <UP> - decreases the angle phi
  328.                 ii) <DOWN> - increases the angle phi
  329.                iii) <LEFT> - decreases the angle theta
  330.                 iv) <RIGHT> - increases the angle theta
  331.  
  332. The diagonal keys can be used as a logical combination of the above.
  333.  
  334. By default, the graph is scaled so that it is viewable from all angles.
  335.  
  336. The following commands are included in a help screen that can be viewed
  337. by pressing <F1> or 'h' while in Graph Mode.
  338.  
  339. 'a'     - Toggle the drawing of the axes
  340. 'c'     - Continuous mode - causes <UP>, <DOWN>, etc. to be repeated until
  341.           any key other than the arrow keys is pressed.
  342. 'd'     - Toggle the drawing of the graph.  This is useful to quickly rotate
  343.           to a desired viewing angle without having to wait for the graph
  344.           to redraw every time.  If 'd' is pressed when the axes are off,
  345.           the axes will automatically be redrawn until 'd' is pressed again.
  346. 'l'     - label the axes
  347. 'p'     - Print the graph from the current viewing angles.
  348. 'r'     - Return graph to original view and reset scaling
  349. 'x'     - Increase or decrease the x axis scaling
  350. 'y'     - Increase or decrease the y axis scaling
  351. 'z'     - Increase or decrease the z axis scaling
  352. <enter> - Toggle increase/decrease action of x,y,z commands
  353.  
  354. To exit from the Graph Mode and return to the main menu, press <ESC>
  355.  
  356.